package cn.edu.hbsi.domain.result;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import io.swagger.v3.oas.annotations.media.Schema;

/**
 * 统一返回结果状态信息类
 *
 */
//@Schema(title = "统一返回结果状态信息")
@ApiModel(description = "统一返回结果状态信息")
public enum ResultCodeEnum {
    SUCCESS(200,"success"),
    USERNAME_ERROR(501,"usernameError"),
    PASSWORD_ERROR(503,"passwordError"),
    NOTLOGIN(504,"notLogin"),
    USERNAME_USED(505,"userNameUsed");

//    @Schema(title = "返回码")
    @ApiModelProperty(value = "返回码")
    private Integer code;
//    @Schema(title = "返回信息")
    @ApiModelProperty(value = "返回信息")
    private String message;
    private ResultCodeEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }
    public Integer getCode() {
        return code;
    }
    public String getMessage() {
        return message;
    }
}

